﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Crossroad.Utils.Extensions
{
    public static class BoolExt
    {

        /// <summary>
        /// bool类型的值是否为false。
        /// </summary>
        /// <param name="value"></param>
        /// <returns></returns>
        public static bool IsFalse(this bool value)
        {
            return value == false;
        }

        /// <summary>
        /// 返回int值
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        public static int IntVal(this bool input)
        {
            return input ? 1 : 0;
        }
    }
}
